#include "StdAfx.h"
#include "AppTestCamera.h"

/*
#include <Physics/Dynamics/Collide/ContactListener/hkpContactListener.h>

class CameraCollisionResponse: public hkReferencedObject, public hkpContactListener
{
public:
	CameraCollisionResponse()
		:hkpContactListener(),m_bCollided(false)
	{
	}

	virtual ~CameraCollisionResponse()
	{
	}

	virtual void contactPointCallback( const hkpContactPointEvent& event_ ) 
	{
		HK_ASSERT2( 0xf455ea07, event_.m_source != hkpCollisionEvent::SOURCE_WORLD, "Do not add this listener to the world." );
		// Disable normal collision response.
		event_.m_contactPointProperties->m_flags |= hkContactPointMaterial::CONTACT_IS_DISABLED;
		hkContactPoint cp = *event_.m_contactPoint;

		// The impulse we apply is a function of the contact normal.
		hkVector4 impulse;
		{
			// If the listener was attached to the B body in this collision, then the contact normal
			// is the wrong way around.
			hkReal factor = ( event_.m_source == hkpCollisionEvent::SOURCE_A ) ? 10.0f : -10.0f;
			impulse.setMul4( factor, event_.m_contactPoint->getNormal() );
		}

		// The sphere is the body to which we added the listener (i.e. the source).
		hkpRigidBody* pCameraSphere = event_.getBody( event_.m_source );

		// We must call accessVelocities prior to applying the impulse, and call updateVelocities afterwards.
		event_.accessVelocities( event_.m_source );
		pCameraSphere->applyLinearImpulse( impulse );
		event_.updateVelocities( event_.m_source );

		m_bCollided = true;
	}

	bool IsCollided( void )
	{
		return m_bCollided;
	}

	void ResetCollidedFlag()
	{
		m_bCollided = false;
	}

private:

	bool m_bCollided;
};
*/

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
TestCamera::TestCamera(void)
{
	this->SetProjParams( D3DX_PI / 4, 1.0f, 1.0f, 1000.0f );
}
TestCamera::~TestCamera(void)
{
}
void TestCamera::FrameMove( FLOAT fElapsedTime )
{
	CFirstPersonCamera::FrameMove( fElapsedTime );
}

float TestCamera::GetMoveSpeed( void ) const
{
	return m_fMoveScaler;
}
